import http from '@/plugins/http/index';

//消息通知中心
export const loadMessageListDataAPI = params => {
	return http.post(`/lt-order/pc_query_notification_by_page.do`, params);
};
//单个消息已读查询
export const readOneMsgCenterInfo = params => {
	return http.get(`/lt-order/read_one_notification.do`, params);
};
// 个人中心查询我的课程
export const loadFinishedLessonAPI = params => {
	return http.post(`/lt-order/select_user_lesson_byPage.do`, params);
};
// 个人中心查询我的收藏
export const loadCollectLessonAPI = params => {
	return http.post(`/lt-order/select_collect_lesson_byPage.do`, params);
};

// // 个人中心---
// // 获取用户信息
// export const getUserInfo = params => {
// 	return http(`/yjz-user/lawtrain/pcUserInfo/selectUserInfoByUserId.do`, params, {
// 		method: 'GET'
// 	}).then(res => res);
// };

// 个人中心查询我的课程
export const allFinishedLesson = params => {
	return http.post(`/lt-order/select_user_lesson.do`, params);
};

//判断是否是VIP用户
export const getUserIsVipAPI = params => {
	return http.get(`/lt-order/quert_user_is_vip`, params).then(res => res);
};

// 订阅服务
export const selectAllSubscribe = params => {
	return http.get(`/lt-order/subscribe/selectAllSubscribe.do`, params).then(res => res);
};

// 个人中心--是否取消收藏该课程
export const hasCancelCollect = params => {
	return http.get(`/lt-order/collect_lesson.do`, params).then(res => res);
};

// // 教师中心--讲师信息查询
// export const getLecturer = params => {
// 	return http(`/yjz-user/select_Lecturer_info.do`, params, {
// 		method: 'GET'
// 	}).then(res => res);
// };

// // 教师中心--教师统计信息
// export const getLecturerCenter = params => {
// 	return http(`/lt-order/sum_lecturer_center.do`, params, {
// 		method: 'GET'
// 	}).then(res => res);
// };

// // 教师中心--教师相关课程查询
// export const getRelatedLesson = params => {
// 	return http(`/lt-order/lecturer_see_byPage.do`, params, {
// 		method: 'POST'
// 	}).then(res => res);
// };

// // 课程统计列表查询
// export const getLecturerQueryByPage = params => {
// 	return http(`/lt-order/lecturer_center_byPage.do`, params, {
// 		method: 'POST'
// 	}).then(res => res);
// };

// // 订阅服务立即购买下单
// export const payLessonInfo = params => {
// 	return http(`/lt-order/payLessonInfo.do`, params, {
// 		method: 'GET'
// 	}).then(res => res);
// };

// // 换取图片在服务器上面的地址
// export const translateImgUrl = params => {
// 	return http(`/lt-order/teacher_pic_upload.do`, params, {
// 		method: 'POST',
// 		type: 'file'
// 	}).then(res => res);
// };

// // 提交用户维护信息
// export const applytUserInfo = params => {
// 	return http(`/yjz-user/lawtrain/pcUserInfo/updateUserInfoByUserId.do`, params, {
// 		method: 'post'
// 	}).then(res => res);
// };

// //验证码验证
// export const checkPhoneCode = params => {
// 	return http(`/yjz-user/lawtrain/pcUserInfo/confirm_code.do`, params, {
// 		method: 'GET'
// 	}).then(res => res);
// };
//获取专属课程
export const getzhuanshulesson = params => {
	return http.post(`/lt-order/wechat/selectExclusiveLessonByPage.do`, params).then(res => res);
};
